# -*- coding: utf-8 -*

class Mail:
    tag = 'mail'

    def __init__(self):
        self.defValue()

    def defValue(self):
        self.pop_server = 'pop.qq.com'
        self.pop_port = '995'
        self.smtp_server = 'smtp.qq.com'
        self.smtp_port = '465'
        self.user = '228953280@qq.com'
        self.pwd = 'uugnowgbesdkbhjb'
        # 上一封邮件唯一标识(重启后，可对比最新邮件)
        self.pre_email = '000'
        # 已经执行过的邮件标识
        self.exe_email = '1001,1002'

    # 备用邮箱服务
    def get_two(self):
        mail = Mail()
        mail.pop_server = 'pop.163.com'
        mail.pop_port = '995'
        mail.smtp_server = 'smtp.163.com'
        mail.smtp_port = '465'
        mail.user = 'bzsome@163.com'
        mail.pwd = 'bzsome163'
        return mail


class Settings:
    tag = 'settings'

    def __init__(self):
        self.defValue()

    def defValue(self):
        self.auto_start = '1'
        self.start_send = '1'
        self.delay = '0'
        self.sleep = '2'
        self.cam_no = 0
        self.whitelist = 'bzsome@163.com,bzsome001@outlook.com'
        self.file_path = 'file'
        self.hide_icon = '0'
        # 是否保存过数据(保存过数据将从配置文件中去读，否则从默认中读取)
        self.user_save = '0'


class Commands:
    tag = 'commands'

    def __init__(self):
        self.defValue()

    def defValue(self):
        self.tag_shutdown = '#shutdown'
        self.tag_screen = '#screen'
        self.tag_cam = '#cam'
        self.tag_button = '#button'
        self.tag_cmd = '#cmd'


class AppInfo:
    tag = 'appInfo'

    def __init__(self):
        self.defValue()

    def defValue(self):
        self.version = '1.2'
        # 设备唯一ID(自动读取，无须配置)
        self.device_id = '0000'
